/*********************************************************************************************
 *
 *				Function to return the address of matching string							 *
 *
 ********************************************************************************************/
#include "mystrings.h"



char  * mystrstr ( const char * main , const char * sub)
{									/* procedure to return the address of found sting  */
	const char  * temp1  =  main ;
	const char  * temp2  =  sub ;

	for  ( ; *temp1 ; temp1++) {
		for ( temp1 = main, temp2 = sub ; *temp1 == *temp2 && temp2 != '\0' ; temp1++,temp2++)
			;
		if ( *temp2 == '\0' )
			return (char *)  main ;
		else 
			main++ ;
	}
	return  (char *)('\0') ;
}

